import Vue from 'vue'
import VueRouter from 'vue-router'
import Login from '@/views/login.vue'
import Index from '@/views/index.vue'
import CompleteOrder from '@/views/completeOrder.vue'
import OrderList from '@/views/orderList.vue'
import OrderDetail from '@/views/orderDetail.vue'
import Voucher from '@/views/voucher.vue'
import BaseView from '@/views/BaseView.vue'

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    name: 'Index',
    component: Index
  },
  {
    path: '/login',
    name: 'Login',
    component: Login
  },
  {
    path: '/completeOrder',
    name: 'CompleteOrder',
    component: CompleteOrder
  },
  {
    path: '/orderList',
    name: 'OrderList',
    component: OrderList
  },
  {
    path: '/orderDetail',
    name: 'OrderDetail',
    component: OrderDetail
  },
  {
    path: '/voucher',
    name: 'Voucher',
    component: Voucher
  }
]

const router = new VueRouter({
  mode: 'hash',
  base: process.env.BASE_URL,
  routes
})

export default router
